﻿using System;
using System.Collections;
using System.Configuration;
using System.Data;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;

namespace seoWebApplication
{
    public partial class WebForm1 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            string message;
            message = "";
            int y = 20;
            bool flag = false;

            message += "<table>";
            message += "<tr>";
             for (int x = 0; x <= y; x++)
                        {
                            if (flag)
                            {
                                message += "<td>";
                            }
                         
                                        if(x>=0 & x<=6) 

                                        {
                                            if (x == 0)
                                            {    
                                                flag = false;
                                                message += "<td>";
                                            }
                                            
                                            message += x.ToString()+"x";
                                            message += "<br>";
                                            if (x == 6)
                                            {
                                                message += "</td>";
                                                flag = true;
                                            }
                                        }

                                     


                                        else if (x >= 7 & x <= 13)
                                        {
                                            if (x == 7)
                                            { 
                                                flag = false;
                                                message += "<td>";
                                            } 
                                            message += x.ToString() + "x";
                                            message += "<br>";
                                            if (x == 13)
                                            {
                                                message += "</td>";
                                                flag = true;
                                            }
                                        }

                                      
                                        else if (x >= 14 & x <= 20)
                                        {
                                            if (x == 14)
                                            { 
                                                flag = false;
                                                message += "<td>";
                                            }
                                            
                                            message += x.ToString() + "x";
                                            message += "<br>";
                                            if (x == 20)
                                            {
                                                message += "</td>";
                                                flag = true;
                                            }
                                        }

                                        if (flag)
                                        {
                                            message += "</td>";
                                        }

                                      

                                }
             message += "</tr>";
             message += "</table>";
             this.Label1.Text = message.ToString();
                        }
         
}
}

           
   
